#ifndef PROXYDESC_H
#define PROXYDESC_H

#include <QNetworkProxy>
#include <QString>
#include <QTime>
#include <QMap>
#include <QDomDocument>

class ProxyDesc : public QNetworkProxy
{
    static int count;
    int _index;
    QMap<QString, QTime> waitMap;
    int _status;
public:
    static const int PENDING=0;
    static const int WORKING=1;
    static const int NOTWORKING=2;

    bool changed;
    ProxyDesc( ProxyType type, const QString & hostName = QString(), quint16 port = 0, const QString & user = QString(), const QString & password = QString() );
    bool canDownload(QString);
    void setStatus(int);
    int status();
    QDomElement xmlDesc(QDomDocument*);
    int index();
signals:

public slots:
    void wait(QString, QTime);
};

#endif // PROXYDESC_H
